package com.cuput.partybuilding;

import android.app.Activity;
import android.app.Application;
import android.content.Context;
import android.content.Intent;
import android.content.pm.PackageInfo;
import android.taobao.atlas.bundleInfo.AtlasBundleInfoManager;
import android.taobao.atlas.framework.Atlas;
import android.taobao.atlas.framework.BundleImpl;
import android.taobao.atlas.framework.BundleInstaller;
import android.taobao.atlas.framework.Framework;
import android.taobao.atlas.runtime.ActivityTaskMgr;
import android.taobao.atlas.runtime.ClassNotFoundInterceptorCallback;
import android.text.TextUtils;
import android.util.Log;
import android.widget.Toast;

import com.cuput.partybuilding.publiclibrary.TempApplication;
import com.cuput.partybuilding.publiclibrary.manager.RetrofitServiceManager;
import com.devin.core.network.OKHttpClientFactory;

import org.osgi.framework.BundleEvent;
import org.osgi.framework.BundleException;
import org.osgi.framework.BundleListener;

import java.io.File;
import java.lang.reflect.Constructor;
import java.lang.reflect.Field;
import java.lang.reflect.Method;
import java.util.HashMap;
import java.util.Random;

import okhttp3.OkHttpClient;

/**
 * Created by wei on 2017-05-05.
 */

public class PartyBuildingApplication extends Application {
    private static Context mContext ;

    @Override
    public void onCreate() {
        super.onCreate();
        mContext = getApplicationContext();

        TempApplication.init(this);

        OkHttpClient okHttpClient = OKHttpClientFactory.defaultOkHttpClient(mContext);
//        okHttpClient = okHttpClient.newBuilder().addInterceptor(new TokenInterceptor()).build();
        RetrofitServiceManager.init(mContext,"http://www.baidu.com",okHttpClient);
    }
}
